package com.ruoyi.system.domain;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.util.Date;

/**
 * 设备位置信息
 *
 * @author ruoyi
 */
@Data
@ApiModel("设备位置信息表")
public class SysDeviceLocation implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "位置ID", required = true)
    private Long id;

    @ApiModelProperty(value = "设备ID", required = true)
    private Long deviceId;

    @ApiModelProperty(value = "用户", required = true)
    private Long userId;

    @ApiModelProperty(value = "用户姓名")
    private String userName;

    @ApiModelProperty(value = "设备标识")
    private String deviceIdentifier;

    @ApiModelProperty(value = "经度", required = true)
    private Double longitude;

    @ApiModelProperty(value = "纬度", required = true)
    private Double latitude;

    @ApiModelProperty(value = "高度（米）")
    private Double altitude;

    @ApiModelProperty(value = "速度（km/h）")
    private Double speed;

    @ApiModelProperty(value = "方向（度）")
    private Double direction;

    @ApiModelProperty(value = "定位精度（米）")
    private Double accuracy;

    @ApiModelProperty(value = "定位类型（0GPS 1基站 2WIFI）")
    private String locationType;

    @ApiModelProperty(value = "定位时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date locationTime;

    @ApiModelProperty(value = "创建时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createTime;
}